package com.xlhj.yucloud.util;

import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;

/**
 * @author: liucaijing
 * @description: 密码工具类
 * @date: 2021/9/26 13:24
 */
public class SecurityUtils {

    /**
     * 生成BCryptPasswordEncoder密码
     * @param password
     * @return
     */
    public static String encryptPassword(String password) {
        BCryptPasswordEncoder passwordEncoder = new BCryptPasswordEncoder();
        return passwordEncoder.encode(password);
    }
}
